package edu.kit.aifb.ruleintegrator.rule.metric;

import uk.ac.shef.wit.simmetrics.similaritymetrics.AbstractStringMetric;
import uk.ac.shef.wit.simmetrics.similaritymetrics.JaccardSimilarity;



public class JaccardFunction extends AbstractFunction{
//	AbstractStringDistance metric = new Jaccard();
//	  AbstractStringMetric metric = new JaccardSimilarity();
//	
//	@Override
//	public double measure(String attr1, String attr2) {
//		return metric.getSimilarity(attr1, attr2);
//	}
//	AbstractStringDistance metric = new Jaccard();
	  AbstractStringMetric metric = new JaccardSimilarity();
	
	@Override
	public double measure(String attr1, String attr2) {
		return metric.getSimilarity(attr1, attr2);
	}

	@Override
	public String getName() {
		return "jaccard";
	}

}
